'use strict';

/**
 * @param {Egg.Application} app - egg application
 */
module.exports = app => {
  const { router, controller } = app;
  router.get('/', controller.home.index);
  //登录
  router.post('/pc/login', controller.login.login)
  //注册
  router.post('/regis', controller.login.regis)
  //获取数据
  router.post('/getlist', controller.home.getlist);
  //删除
  router.delete('/getdel', controller.home.getdel);
  //搜索
  router.post('/search', controller.home.search);
  //增
  router.put('/api/appEnd', controller.home.append);
  //改
  router.post('/api/amEnd', controller.home.amend);
};
